Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Events view #1592

Merged
merged 5 commits into from
Jun 14, 2022
Merged

Add Events view #1592

merged 5 commits into from
Jun 14, 2022

Conversation

rszwajko
Copy link
Member

Depends on PR #1585

Changes on the VM Details -> Overview Card:

  1. display last 2 events that are associated with the VM
  2. provide a "View All" link to a new sub-page: the Events view.

Events view features:

  1. display events in a table with 3 columns:
    a) severity
    b) date (includes time)
    c) message
  2. allow filtering and sorting for all columns via toolbar
  3. limit the max number of events that can be fetched to 500
  4. do incremental refresh by fetching only new events

@rszwajko rszwajko requested review from sjd78 and sgratch May 18, 2022 15:38
@ovirt-infra
Copy link

All tests passed

@rszwajko
Copy link
Member Author

Last 2 events on the Overview Card

image

Events view

The table

image

Small screen

image

Filters

image

No events found

image

@ovirt-infra
Copy link

All tests passed

@ovirt-infra
Copy link

All tests passed

@ovirt-infra
Copy link

All tests passed

@ovirt-infra
Copy link

All tests passed

@ovirt-infra
Copy link

All tests passed

@ovirt-infra
Copy link

All tests passed

@ovirt-infra
Copy link

All tests passed

@ovirt-infra
Copy link

All tests passed

@rszwajko
Copy link
Member Author

rszwajko commented Jun 9, 2022

Changes in the last force push:

  1. sort via table header
  2. sticky header
  3. display the number of results in the toolbar

@rszwajko rszwajko linked an issue Jun 9, 2022 that may be closed by this pull request
@ovirt-infra
Copy link

All tests passed

sjd78 added a commit to sjd78/ovirt-web-ui that referenced this pull request Jun 9, 2022
After merging PRs and pushing their string changes, pull the
translations.  This picks up translation invalidations (English text
has changed), helping to make sure the translations are not wrong.

PRs to consider:
  - oVirt#1533
  - oVirt#1537
  - oVirt#1539
  - oVirt#1540
  - oVirt#1543
  - oVirt#1549
  - oVirt#1564
  - oVirt#1584
  - oVirt#1585 ** pending merge
  - oVirt#1592 ** pending merge
rszwajko added 4 commits June 14, 2022 19:49
Before, filtering and sorting was tied to VM entities. After this patch
the generic filter/sort component can be reused for other entities.

Filter component changes:
1. create a new type of filter - a date filter
2. generalize name filter to text based filter - as before only one
   filter of this type is supported per filter toolbar
3. extract enum based filter as SelectFilter

Sort component changes:
1. refactor SortFields from constant to parameter
2. drop unused isNumeric flag - natural sort order is used for all
   types of input
Changes on the VM Details -> Overview Card:
1. display last 2 events that are associated with the VM
2. provide a "View All" link to a new sub-page: the Events view.

Events view features:
1. display events in a table with 3 columns:
  a) severity
  b) date (includes time)
  c) message
2. allow filtering and sorting for all columns via toolbar
3. limit the max number of events that can be fetched to 500
4. do incremental refresh by fetching only new events
@ovirt-infra
Copy link

All tests passed

@ovirt-infra
Copy link

All tests passed

@rszwajko rszwajko removed the PF4 label Jun 14, 2022
@rszwajko rszwajko requested a review from sjd78 June 14, 2022 19:56
Copy link
Member

@sjd78 sjd78 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

sjd78 added a commit to sjd78/ovirt-web-ui that referenced this pull request Jun 14, 2022
After merging PRs and pushing their string changes, pull the
translations.  This picks up translation invalidations (English text
has changed), helping to make sure the translations are not wrong.

PRs to consider:
  - oVirt#1533
  - oVirt#1537
  - oVirt#1539
  - oVirt#1540
  - oVirt#1543
  - oVirt#1549
  - oVirt#1564
  - oVirt#1584
  - oVirt#1585
  - oVirt#1592 ** pending merge
@sjd78 sjd78 merged commit 3705acc into oVirt:master Jun 14, 2022
sjd78 added a commit to sjd78/ovirt-web-ui that referenced this pull request Jun 14, 2022
After merging PRs and pushing their string changes, pull the
translations.  This picks up translation invalidations (English text
has changed), helping to make sure the translations are not wrong.

PRs to consider:
  - oVirt#1533
  - oVirt#1537
  - oVirt#1539
  - oVirt#1540
  - oVirt#1543
  - oVirt#1549
  - oVirt#1564
  - oVirt#1584
  - oVirt#1585
  - oVirt#1592
rszwajko added a commit to rszwajko/forklift-console-plugin that referenced this pull request Aug 31, 2022
rszwajko added a commit to rszwajko/forklift-console-plugin that referenced this pull request Aug 31, 2022
Changes:
1. display all providers in ons table
2. provide attribute-value filter implementation with:
  a) free text filter
  b) enum based filter

Reference-Url: oVirt/ovirt-web-ui#1600
Reference-Url: oVirt/ovirt-web-ui#1592
Reference-Url: https://www.patternfly.org/v4/guidelines/filters#attribute-value-filter
rszwajko added a commit to rszwajko/forklift-console-plugin that referenced this pull request Sep 6, 2022
Functional changes:
1. display all providers in one table
2. use only 'Ready' condition to describe the state of the provider

Components created:
1. primary filters component for displaying few (1-3) most important
   filters. The filters are grouped but displayed independently.
2. attribute-value filter implementation for grouping all other filters
   in a space efficient way
3. default filter types:
  a) free text filter
  - substring search based on multiple terms
  - search terms confirmed by 'Enter' key
  b) enum based filter
  - exact match based on checkboxes selected
4. generic table component providing sorting capabilities

Reference-Url: oVirt/ovirt-web-ui#1600
Reference-Url: oVirt/ovirt-web-ui#1592
Reference-Url: https://www.patternfly.org/v4/guidelines/filters#attribute-value-filter
rszwajko added a commit to rszwajko/forklift-console-plugin that referenced this pull request Sep 12, 2022
Functional changes:
1. display all providers in one table
2. use only 'Ready' condition to describe the state of the provider

Components created:
1. primary filters component for displaying few (1-3) most important
   filters. The filters are grouped but displayed independently.
2. attribute-value filter implementation for grouping all other filters
   in a space efficient way
3. default filter types:
  a) free text filter
  - substring search based on multiple terms
  - search terms confirmed by 'Enter' key
  b) enum based filter
  - exact match based on checkboxes selected
4. generic table component providing sorting capabilities

Reference-Url: oVirt/ovirt-web-ui#1600
Reference-Url: oVirt/ovirt-web-ui#1592
Reference-Url: https://www.patternfly.org/v4/guidelines/filters#attribute-value-filter
rszwajko added a commit to rszwajko/forklift-console-plugin that referenced this pull request Sep 20, 2022
Functional changes:
1. display all providers in one table
2. use only 'Ready' condition to describe the state of the provider

Components created:
1. primary filters component for displaying few (1-3) most important
   filters. The filters are grouped but displayed independently.
2. attribute-value filter implementation for grouping all other filters
   in a space efficient way
3. default filter types:
  a) free text filter
  - substring search based on multiple terms
  - search terms confirmed by 'Enter' key
  b) enum based filter
  - exact match based on checkboxes selected
4. generic table component providing sorting capabilities

Reference-Url: oVirt/ovirt-web-ui#1600
Reference-Url: oVirt/ovirt-web-ui#1592
Reference-Url: https://www.patternfly.org/v4/guidelines/filters#attribute-value-filter
rszwajko added a commit to rszwajko/forklift-console-plugin that referenced this pull request Sep 23, 2022
Functional changes:
1. display all providers in one table
2. use only 'Ready' condition to describe the state of the provider

Components created:
1. primary filters component for displaying few (1-3) most important
   filters. The filters are grouped but displayed independently.
2. attribute-value filter implementation for grouping all other filters
   in a space efficient way
3. default filter types:
  a) free text filter
  - substring search based on multiple terms
  - search terms confirmed by 'Enter' key
  b) enum based filter
  - exact match based on checkboxes selected
4. generic table component providing sorting capabilities

Reference-Url: oVirt/ovirt-web-ui#1600
Reference-Url: oVirt/ovirt-web-ui#1592
Reference-Url: https://www.patternfly.org/v4/guidelines/filters#attribute-value-filter
rszwajko added a commit to rszwajko/forklift-console-plugin that referenced this pull request Oct 4, 2022
Functional changes:
1. display all providers in one table
2. use only 'Ready' condition to describe the state of the provider

Components created:
1. primary filters component for displaying few (1-3) most important
   filters. The filters are grouped but displayed independently.
2. attribute-value filter implementation for grouping all other filters
   in a space efficient way
3. default filter types:
  a) free text filter
  - substring search based on multiple terms
  - search terms confirmed by 'Enter' key
  b) enum based filter
  - exact match based on checkboxes selected
4. generic table component providing sorting capabilities

Reference-Url: oVirt/ovirt-web-ui#1600
Reference-Url: oVirt/ovirt-web-ui#1592
Reference-Url: https://www.patternfly.org/v4/guidelines/filters#attribute-value-filter

Signed-off-by: Radoslaw Szwajkowski <[email protected]>
rszwajko added a commit to rszwajko/forklift-console-plugin that referenced this pull request Oct 10, 2022
Functional changes:
1. display all providers in one table
2. use only 'Ready' condition to describe the state of the provider

Components created:
1. primary filters component for displaying few (1-3) most important
   filters. The filters are grouped but displayed independently.
2. attribute-value filter implementation for grouping all other filters
   in a space efficient way
3. default filter types:
  a) free text filter
  - substring search based on multiple terms
  - search terms confirmed by 'Enter' key
  b) enum based filter
  - exact match based on checkboxes selected
4. generic table component providing sorting capabilities

Reference-Url: oVirt/ovirt-web-ui#1600
Reference-Url: oVirt/ovirt-web-ui#1592
Reference-Url: https://www.patternfly.org/v4/guidelines/filters#attribute-value-filter

Signed-off-by: Radoslaw Szwajkowski <[email protected]>
rszwajko added a commit to rszwajko/forklift-console-plugin that referenced this pull request Oct 20, 2022
Functional changes:
1. display all providers in one table
2. use only 'Ready' condition to describe the state of the provider

Components created:
1. primary filters component for displaying few (1-3) most important
   filters. The filters are grouped but displayed independently.
2. attribute-value filter implementation for grouping all other filters
   in a space efficient way
3. default filter types:
  a) free text filter
  - substring search based on multiple terms
  - search terms confirmed by 'Enter' key
  b) enum based filter
  - exact match based on checkboxes selected
4. generic table component providing sorting capabilities

Reference-Url: oVirt/ovirt-web-ui#1600
Reference-Url: oVirt/ovirt-web-ui#1592
Reference-Url: https://www.patternfly.org/v4/guidelines/filters#attribute-value-filter

Signed-off-by: Radoslaw Szwajkowski <[email protected]>
rszwajko added a commit to rszwajko/forklift-console-plugin that referenced this pull request Oct 28, 2022
Components created:
1. standard list page component
  a) page skeleton following openshift console layout and practice
  b) generic component parametrized by the entity type
  c) design is view independent and follows the approach used in oVirt
     PR 1600 and 1592. Currently only table view implementation is
     provided.
2. primary filters component
  a) implementation of PatternFly 4 filter group pattern[1] extended to
     support all filters implementing FilterTypeProps interface.
  b) use case: displaying few (1-3) most important filters.
     The filters are grouped but displayed independently.
3. attribute-value filter component
  a) implementation of PatternFly 4 attribute-value filter pattern[2]
  b) use case: grouping all other filters in a space efficient way
  c) supports all filters implementing FilterTypeProps interface.
4. filter components:
  a) free text filter
   - substring search based on multiple terms
   - search terms confirmed by 'Enter' key or by button
  b) enum based filter
   - exact match based on checkboxes selected
5. table view component
  a) parametrized by the entity type
  b) row mapper component is entity-specific which allows complex
     customizations
  c) sorting capabilities (via arrows in the table header)
6. dialog for managing column visibility and order
  a) based on openshift console solution [3] and PatternFly 4 demo[4]
  b) toggle column visibility (except identity columns)
  c) re-order columns using drag and drop

Updated libraries:
1. Downgrade @testing-library/react to ^12.0 since ^13.0 requires
   react >= 18.
2. Bump @openshift/dynamic-plugin-sdk* to 1.0.0

[1] https://www.patternfly.org/v4/guidelines/filters/#filter-group
[2] https://www.patternfly.org/v4/guidelines/filters#attribute-value-filter
[3] https://github.com/openshift/console/blob/release-4.12/frontend/public/components/modals/column-management-modal.tsx
[4] https://www.patternfly.org/v4/components/table/react-demos#column-management-with-draggable

Reference-Url: oVirt/ovirt-web-ui#1600
Reference-Url: oVirt/ovirt-web-ui#1592
Signed-off-by: Radoslaw Szwajkowski <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Visiblity of VM events
3 participants